package model;

import java.util.ArrayList;
import java.util.List;

public class File {
	
	private final int numberOfPieces=20;
	private int filePieceIDCounter;
	private double fileSize;

	private List<FilePiece> pieceList;
	
	public File(){
		pieceList = new ArrayList<FilePiece>();
		
		for(filePieceIDCounter=0; filePieceIDCounter<numberOfPieces; filePieceIDCounter++){
			FilePiece newFilePiece = new FilePiece(filePieceIDCounter);
			pieceList.add(newFilePiece);
			fileSize += newFilePiece.getDataSize();
		}
	}
	
	public List<FilePiece> getFilePieces(){
		return pieceList;
	}
	
	public double getFileSize(){
		return fileSize;
	}
	
}
